package com.framework.loippi.entity;

import com.framework.loippi.mybatis.eitity.GenericEntity;
import com.framework.loippi.mybatis.ext.annotation.Column;
import com.framework.loippi.mybatis.ext.annotation.Table;

import org.springframework.format.annotation.DateTimeFormat;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * Entity - 平台流水记录
 * 
 * @author wmj
 * @version 2.0
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Table(name = "T_FLOW_RECORD")
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonIgnoreProperties({ "handler","hibernateLazyInitializer" }) 
@ApiModel(value="平台流水记录",description="平台流水记录")
public class FlowRecord implements GenericEntity {

	private static final long serialVersionUID = 5081846432919091193L;

	/** id */
	@Column(id = true, name = "id", updatable = false)
	@ApiModelProperty(value = "id")
	private Long id;
	
	/** 流水号 */
	@Column(name = "sn" )
	@ApiModelProperty(value = "流水号")
	private String sn;
	
	/** 订单id */
	@Column(name = "order_id" )
	@ApiModelProperty(value = "订单id")
	private Long orderId;
	
	/** 订单号 */
	@Column(name = "order_sn" )
	@ApiModelProperty(value = "订单号")
	private String orderSn;
	
	/** 订单事由（1：订单收入，2：售后退款） */
	@Column(name = "order_type" )
	@ApiModelProperty(value = "订单事由（1：订单收入，2：售后退款）")
	private Integer orderType;
	
	/** 用户id */
	@Column(name = "user_id" )
	@ApiModelProperty(value = "用户id")
	private Long userId;
	
	/** 用户姓名 */
	@Column(name = "user_name" )
	@ApiModelProperty(value = "用户姓名")
	private String userName;
	
	/** 手机号 */
	@Column(name = "phone" )
	@ApiModelProperty(value = "手机号")
	private String phone;
	
	/** 交易类型（1：收入，2：支出） */
	@Column(name = "type" )
	@ApiModelProperty(value = "交易类型（1：收入，2：支出）")
	private Integer type;
	
	/** 金额 */
	@Column(name = "amount" )
	@ApiModelProperty(value = "金额")
	private java.math.BigDecimal amount;
	
	/** 支付方式(1-微信，2-支付宝) */
	@Column(name = "pay_mode" )
	@ApiModelProperty(value = "支付方式(1-微信，2-支付宝)")
	private Integer payMode;
	
	/** 到账方式(1-微信，2-支付宝) */
	@Column(name = "receiver_mode" )
	@ApiModelProperty(value = "到账方式(1-微信，2-支付宝)")
	private Integer receiverMode;
	
	/** 创建时间 */
	@Column(name = "creat_time" )
	@ApiModelProperty(value = "创建时间")
	private java.util.Date creatTime;
	
	/** 备注 */
	@Column(name = "remark" )
	@ApiModelProperty(value = "备注")
	private String remark;
	
	/** 退款状态（2：未退款，1：已退款） */
	@Column(name = "is_refund" )
	@ApiModelProperty(value = "退款状态（2：未退款，1：已退款）")
	private Integer isRefund;
	
}
